class MallGoodsEntity {
  String image;
  double oriPrice;
  double presentPrice;
  String goodsId;
  String goodsName;

  MallGoodsEntity({this.image, this.oriPrice, this.presentPrice, this.goodsId, this.goodsName});

  MallGoodsEntity.fromJson(Map<String, dynamic> json) {
    image = json['image'];
    oriPrice = json['price'] == null ? json['oriPrice'] : json['price'];
    presentPrice = json['mallPrice'] == null ? json['presentPrice'] : json['mallPrice'];
    goodsId = json['goodsId'];
    goodsName = json['name'] == null ? json['goodsName'] : json['name'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['image'] = this.image;
    data['oriPrice'] = this.oriPrice;
    data['presentPrice'] = this.presentPrice;
    data['goodsId'] = this.goodsId;
    data['goodsName'] = this.goodsName;
    return data;
  }
}
